<template>
  <div class="container">
    <h1 class="font-weight-100 text-center">问卷调查系统</h1>
    <!-- 按钮 -->
    <div class="mb-15">
      <el-button type="primary" :icon="Plus" @click="goToEditor">创建问卷</el-button>
      <el-button type="success" :icon="Compass" @click="goToMaterials">组件市场</el-button>
    </div>
    <el-table :data="tableData" border style="width: 100%">
      <el-table-column prop="createDate" label="创建日期" width="180" />
      <el-table-column prop="pollName" label="问卷标题" width="280" />
      <el-table-column prop="questions" label="题目数" />
      <el-table-column prop="lasted" label="最新更新" />
      <el-table-column prop="operation" label="操作" />
    </el-table>
  </div>
</template>
<script setup lang="ts">
// 导入注册的图标
import { Plus, Compass } from '@element-plus/icons-vue'
import { ref } from 'vue';
import { useRouter } from 'vue-router';
const tableData = ref([])
const router = useRouter()
const goToEditor = ()=>{
    router.push({name:"editor"})
}
const goToMaterials = ()=>{
    router.push({name:"materials"})
    
}
// const
</script>

<style scoped lang="ts"></style>
